package Utility;

/**
 * @category Utility module
 * @author Sean Lionheart
 * @version 1.0.0.0
 * The log entry, which contains the message and the category of the log.
 */
public class LogEntry {
	private String logMessage;		//The message of the log.
	private int logCategory;		//The category of the log.
	
	public String getLogMessage() {
		return logMessage;
	}
	public void setLogMessage(String logMessage) {
		this.logMessage = logMessage;
	}
	public int getLogCategory() {
		return logCategory;
	}
	public void setLogCategory(int logCategory) {
		this.logCategory = logCategory;
	}
	
	public LogEntry(String logMessage, int logCategory) {
		this.logMessage = logMessage;
		this.logCategory = logCategory;
	}
	public String getCategoryString() {
		switch (logCategory) {
		case LogContext.LOG_DEBUG:
			return "DEBUG:";
		case LogContext.LOG_EXCEPTION:
			return "EXCEPTION";
		case LogContext.LOG_INFO:
			return "INFO";
		case LogContext.LOG_WARNING:
			return "WARNING";
		default:
			return "INFO:";
		}
		
	}
	
}
